import webspider.mysql.mysql as mysql
from webspider.settings import MYSQL_TB


def create_table():
    sql = """
            CREATE TABLE {}(
           a int not null,
           b int not null,
           c int not null,
             PRIMARY KEY (a,b))
            """.format(MYSQL_TB)

    with mysql.DB(host='localhost', user='root', passwd='123456', db='51job') as db:
        db.execute(sql)


create_table()
